package es.agroservicio.Agroservicio.domain;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.NotEmpty;

@Entity
@Table(name = "Productos")
public class Product {
	
	@Id
	@Column(name = "IdPro")
	@NotEmpty
	private int idProduct;
	
	@Column(name = "Nombre")
	@NotEmpty
	@Length(max = 100)	
	private String name;
	
	@Column(name = "StockMinimo")	
	private int minStock;
	
	@Column(name = "Descripcion")
	@Length(max = 510)	
	private String description;
	
	@Column(name = "Cantidad")
	private int cuantity;
	
	@Column(name = "PVP")
	@NotEmpty	
	private Float pvp;
	
	@Column(name = "PrecioUnidad")
	@NotEmpty
	private Float unitPrice;
	
	@Column(name = "Categoria")
	@Length(max = 100)	
	private String category;
	
	public int getIdProduct() {
		return idProduct;
	}

	public void setIdProduct(int idProduct) {
		this.idProduct = idProduct;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public int getMinStock() {
		return minStock;
	}

	public void setMinStock(int minStock) {
		this.minStock = minStock;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public int getCuantity() {
		return cuantity;
	}

	public void setCuantity(int cuantity) {
		this.cuantity = cuantity;
	}

	public Float getPvp() {
		return pvp;
	}

	public void setPvp(Float pvp) {
		this.pvp = pvp;
	}

	public Float getUnitPrice() {
		return unitPrice;
	}

	public void setUnitPrice(Float unitPrice) {
		this.unitPrice = unitPrice;
	}

	public String getCategory() {
		return category;
	}

	public void setCategory(String category) {
		this.category = category;
	}

	public String getSupplier() {
		return supplier;
	}

	public void setSupplier(String supplier) {
		this.supplier = supplier;
	}

	@Column(name = "Proveedor")
	@NotEmpty
	@Length(max = 100)	
	private String supplier;
	

}
